// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import API from '@/api/api.js'
import http from "../../api/http";
import config from '@/config'
//
// var rewrites = {
//   rewrites: [{
//     from: '/Frame', // 正则或者字符串
//     to: '/Frame.html', // 字符串或者函数
//   }]
// }
// // SPA应用浏览器回退支持
// // 多页网站可以直接注释掉
// var historyMiddleware = require('connect-history-api-fallback')(rewrites);
// // handle fallback for HTML5 history API
// Vue.use(historyMiddleware)

Vue.use(ElementUI);

Vue.config.productionTip = false

Vue.prototype.$api = API

Vue.prototype.$http = http

Vue.prototype.$config = config

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  components: { App },
  template: '<App/>'
})
